#ifndef JOYSTICK_H
#define JOYSTICK_H

#include <OISJoyStick.h>
#include "yaef_input.h"

class Joystick: public InputDevice, public OIS::JoyStickListener
{
  OIS::JoyStick* _joystick;

public:
  Joystick(QObject* parent=0);

  virtual bool buttonPressed(const OIS::JoyStickEvent &, int);
  virtual bool buttonReleased(const OIS::JoyStickEvent &, int button);
  virtual bool axisMoved(const OIS::JoyStickEvent &arg, int axis);

  void init(OIS::InputManager *mgr);
  void capture();
};

#endif // JOYSTICK_H
